import { ApiProperty } from '@nestjs/swagger';
import { Column, Entity } from 'typeorm';
import { BaseEntity } from '../../../base.entity';

@Entity({ name: 'base_color' })
export default class BaseColor extends BaseEntity {
  @Column({ type: 'varchar', unique: true, length: 50, name: 'color_code', comment: '水墨编码' })
  @ApiProperty()
  colorCode: string;

  @Column({ type: 'varchar', length: 100, name: 'color_name', comment: '水墨名称' })
  @ApiProperty()
  colorName: string;

  @Column({ type: 'varchar', nullable: true, length: 50, comment: '颜色值' })
  @ApiProperty()
  color: string;

  @Column({ type: 'varchar', nullable: true, length: 50, name: 'color_model', comment: '水墨型号' })
  @ApiProperty()
  colorModel: string;

  @Column({ type: 'varchar', nullable: true, length: 50, name: 'brand', comment: '品牌' })
  @ApiProperty()
  brand: string;

  @Column({ type: 'varchar', nullable: true, length: 50, name: 'viscosity', comment: '粘度(秒)' })
  @ApiProperty()
  viscosity: string;

  @Column({
    type: 'varchar',
    nullable: true,
    length: 50,
    name: 'unit_price',
    comment: '单价(元/千克)',
  })
  @ApiProperty()
  unitPrice: string;

  @Column({
    type: 'varchar',
    nullable: true,
    length: 50,
    name: 'color_type_code',
    comment: '水墨类型编码',
  })
  @ApiProperty()
  colorTypeCode: string;

  @Column({
    type: 'varchar',
    nullable: true,
    length: 50,
    name: 'color_type_name',
    comment: '水墨类型名称',
  })
  @ApiProperty()
  colorTypeName: string;

  @Column({ type: 'varchar', nullable: true, comment: '备注' })
  @ApiProperty()
  remark: string;
}
